In general, networks and computers operate in different manners. Networks operate by transferring data in streams and/or packets. Streams may be bit-sized, byte-sized, or otherwise broken down. Packets may be of relatively large size, such as 64, 512, or more bytes each. Computers operate by processing data, typically in well-defined small sizes, such as bytes (8 bits), words (16 bits), double words (32 bits) and so on. At the interface between a computer and a network, a translation or reorganization of data may be necessary. This may include reorganizing data from a series of packets into a format useful to a processor. In particular, this may include taking data bits of a series of bytes and reorganizing them into a form including only data bits. A similar problem may occur at a byte-level, wherein some bytes of a group of bytes are data bytes, and other bytes are effectively control bytes which need to be parsed out of data. Moreover, some control data may be provided in very small packets (as few as 3 bytes), whereas many systems are predicated on a minimum packet length on the order of 8-10 bytes.
In some embodiments, it is common to handle small packets in a physical link layer, by stuffing those packets with extra bytes to create a minimum-length packet. For example, a minimum length may be set to 9 or 10 bytes, and any packets detected with a shorter length may be padded with extra bytes to achieve this minimum length. Referring to FIG. 1, an embodiment of a conventional method of handling a small packet in flow diagram form is illustrated. At block 110, the small packet is detected in the physical link layer. At block 120, the small packet is stuffed with extra bytes to achieve a minimum length of the packet for purposes of future processing. At block 130, the small packet as stuffed is then transferred to the associated framer component for further processing.
This adds complexity to the physical link layer, and requires processing to discard the extra bytes of padding later in the process of utilizing these packets. Effectively, this is creating extra work and extra complexity for the purpose of simplifying some of the associated circuitry. Whether the extra bytes are stripped in the framer or in a later stage of the processing circuitry, they will not be used by the end system and carry no useful information.